package net.xo68.destiny.manager.controller;

import com.github.pagehelper.PageInfo;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import net.xo68.destiny.manager.entity.NodeMonitor;
import net.xo68.destiny.manager.service.NodeMonitorService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;



/** 
 * NodeMonitor controller
 * @author wuxie(16349023@qq.com)
 * @date 2020年12月14日 11:10:13
 *
 */
 @Api(value = "NodeMonitor",tags = {"NodeMonitor"})
@RequestMapping("/NodeMonitor")
@Slf4j
@RestController
public class NodeMonitorController{

    @Autowired
    private NodeMonitorService nodeMonitorService;


    @ApiOperation(value="翻页列表")
    @GetMapping("/list")
    public PageInfo<NodeMonitor> list(@RequestParam(name="pageIndex",defaultValue="1") int pageIndex,@RequestParam(name="pageSize",defaultValue="10") int pageSize){
        return nodeMonitorService.list(pageIndex, pageSize);
    }

}